namespace Digitalmes.Application.Scada.Events;

/// <summary>
/// 产品存档后处理事件。
/// </summary>
public sealed record AfterOutboundEvent : INotification
{
    [NotNull]
    public string? SN { get; init; }

    /// <summary>
    /// 产线 Id
    /// </summary>
    public long LineId { get; init; }

    /// <summary>
    /// 线体编号
    /// </summary>
    [NotNull]
    public string? LineCode { get; init; }

    /// <summary>
    /// 工位 Id
    /// </summary>
    public long WorkstationId { get; set; }

    /// <summary>
    /// 工位编号
    /// </summary>
    [NotNull]
    public string? WorkstationCode { get; init; }

    /// <summary>
    /// 工序Id
    /// </summary>
    public long OperationId { get; init; }

    /// <summary>
    /// 工序编号
    /// </summary>
    [NotNull]
    public string? OperationCode { get; init; }

    /// <summary>
    /// 工序额外存储数据。
    /// </summary>
    public string? OperationTag { get; init; }

    /// <summary>
    /// 过站结果。
    /// </summary>
    public PassEnum PassResult { get; init; }

    /// <summary>
    /// 执行的工艺步骤 Id
    /// </summary>
    public long StepExecutionId { get; init; }
}
